<template>
  <van-col span="8">
    <div class="colleItem">
      <div class="imgBox" @click="$emit('intoDetail', item.pid)">
        <img class="imgCover" :src="item.smallImg" />
      </div>
      <div class="goods">
        <div class="goodsName">
          <p>{{ item.name }}</p>
          <p>{{ item.enname }}</p>
        </div>
        <div class="goodsBottom">
          <p class="money">&yen;{{ item.price }}</p>
          <p v-if="isColle">
            <van-icon
              name="delete-o"
              size="18"
              @click="$emit('remove', item.pid)"
            />
          </p>
        </div>
      </div>
    </div>
  </van-col>
</template>

<script>
export default {
  name: "GoodsList",
  props: {
    item: {
      type: Object,
      default() {
        return {};
      },
    },
    isColle: Boolean,
  },
};
</script>

<style lang="less" scoped>
</style>